<template>
  <div>About</div>
  <p>{{ count }}</p>
</template>

<script lang="ts">
export default {
  name: "About",
};
</script>

<script lang="ts" setup>
const count = useCount();

useHead({
  title: "关于页",
});

const route = useRoute();
console.log(route);

// 1. 定义匿名/内联中间件
definePageMeta({
  // middleware: [
  //   (to, from) => {
  //     // to要去路由对象
  //     // from从哪来的路由对象
  //     console.log(to, from);
  //     // return navigateTo("/detail/111");
  //   },
  // ],
  // 2. 使用路由中间件
  middleware: "test",
});
</script>

<style scoped></style>
